package br.com.werp.suporte.Acesso;
import java.util.*;
import org.apache.struts.action.*;
import javax.servlet.http.*;

/**
 * Creation Date 20/02/2006 09:56:43
 * Last Modify Date 27/04/2006 16:49:11
 */

public class UrlActionForm extends org.apache.struts.action.ActionForm {
  public String url_path;
  private boolean valida = false;
  public UrlActionForm() {
  }
  /**
    * URL_PATH: Gets the value of this field.
    */
  public String getUrl_path() {
    return url_path;
  }
  /**
     * URL_PATH: Sets thhe value for this field.
     */
  public void setUrl_path(String URL_PATH) {
    url_path = URL_PATH;
  }
  /**
    * Reset all fields.
    */
  public void reset(org.apache.struts.action.ActionMapping mapping,
      javax.servlet.http.HttpServletRequest request) {
    url_path = null;
  }
  /**
    * Validate fields and return ActionErrors.
    */

  public ActionErrors validate(org.apache.struts.action.ActionMapping mapping,
      javax.servlet.http.HttpServletRequest request) {
    ActionErrors errors = new ActionErrors();
    valida = false;
    if (com.egen.util.text.Validate.isValidate("insert_action,", request)) {
      if (com.egen.util.text.Validate.isNull(url_path)) {
        errors.add("ActionErrors.GLOBAL_ERROR",
            new ActionError("error.validate.notnull","Url Path","url_path",
                "0"));
      }
    }
    if (errors != null && errors.size() > 0) {
      javax.servlet.http.HttpSession session = request.getSession(true);
      ActionForward actionForward = null;
      session.setAttribute(mapping.getName(), this);
    }
    return errors;
  }
}
